annexInsteadOf config
authorJoey Hess <joeyh@joeyh.name>
Tue, 3 Dec 2024 18:01:35 +0000 (14:01 -0400)
committerJoey Hess <joeyh@joeyh.name>
Tue, 3 Dec 2024 18:39:07 +0000 (14:39 -0400)
commitdd052dcba1528a72b7d0bc3e820cd1a2610e3120
treeb7da6413515fb6302a25e64225a26b2e4f772540
parent0404968d104272039401fd7f9bb46f31298646c1
annexInsteadOf config

Added config `url.<base>.annexInsteadOf` corresponding to git's
`url.<base>.pushInsteadOf`, to configure the urls to use for accessing the
git-annex repositories on a server without needing to configure
remote.name.annexUrl in each repository.

While one use case for this would be rewriting urls to use annex+http,
I decided not to add any kind of special case for that. So while
git-annex p2phttp, when serving multiple repositories, needs an url
of eg "annex+http://example.com/git-annex/ for each of them, rewriting an
url like "https://example.com/git/foo/bar" with this config set to
"https://example.com/git/" will result in eg
"annex+http://example.com/git-annex/foo/bar", which p2phttp does not
support.

That seems better dealt with in either git-annex p2phttp or a http
middleware, rather than complicating the config with a special case for
annex+http.

Anyway, there are other use cases for this that don't involve annex+http.
CHANGELOG
Git/Remote.hs
Git/Types.hs
Remote/Git.hs
Types/GitConfig.hs
doc/git-annex.mdwn
doc/todo/copy__47__move_support_for_pushinsteadOf_/comment_8_8604dfafa32ebb14281c2c866214a920._comment